<?php $today=getdate();?>
<div id="box">
  <form action="<?php echo base_url();?>admin/hotelroomprice/<?php if(isset($_GET['id'])) echo "update?hotelid=".$_GET['hotelid']."&roomid=".$_GET['roomid']."&id=".$detail['id'];else echo "insert?hotelid=".$_GET['hotelid']."&roomid=".$_GET['roomid'];?>" method="post">
    <fieldset id="person">
      <legend>&nbsp;&nbsp;<?php if(isset($_GET['id'])) echo "Edit "; else echo "Insert ";?> Hotel's Room&nbsp;&nbsp;</legend>
      <label>ID : </label>
      <?php echo $detail['id'] ?><br>
      <label>Price : </label>
      <input type="text" name="price" value="<?php echo $detail['price'] ?>"/>
      <br>
      <label>Price for Extra Bed: </label>
      <input type="text" name="extra" value="<?php echo $detail['extra'] ?>"/>
      <br>
      <label>Price for Child : </label>
      <input type="text" name="priceforchild" value="<?php echo $detail['priceforchild'] ?>"/>
      <br>
      <label>Old Price : </label>
      <input type="text" name="oldprice" value="<?php echo $detail['oldprice'] ?>"/>
      <br>
      <label>From Date : </label>
      <input type="text" name="fromdate" class="datepicker" value="<?php if(count($detail['fromdate'])>0) echo date('Y-m-d',strtotime($detail['fromdate']));else echo $today['year']."-".$today['mon']."-".$today['mday'] ?>"/>
      <br>
      <label>To Date : </label>
      <input type="text" name="todate" class="datepicker" value="<?php if(count($detail['todate'])>0) echo date('Y-m-d',strtotime($detail['todate']));else echo $today['year']."-".$today['mon']."-".$today['mday'] ?>"/>
      <br>
      <label>Status</label>
      <select name="status">
        <option value="-1">Choice Status</option>
        <option value="0" <?php if($detail['status']==0) echo "selected";?>>Highlights</option>
        <option value="1" <?php if($detail['status']==1) echo "selected";?>>Normal</option>
        <option value="2" <?php if($detail['status']==2) echo "selected";?>>Hide</option>
      </select>
      <br>
      <div style="float:left;padding-top:5px;padding-left:40%;">
        <input type="reset" value="Reset">
        &nbsp;&nbsp;&nbsp;&nbsp;
        <input type="submit" value="Submit">
      </div>
    </fieldset>
  </form>
</div>
